package org.istt.dao;

import java.util.List;

import org.istt.domain.User;


public interface UserDao extends Dao<User, Long> {
    public List<User> getUsers();
    public User getUser(Long userId);
    public void saveUser(User user);
    public void removeUser(Long userId);
    public List<User> findByUserName(String username);
    public List<User> findUser(String username, String lastname, String firstname, Long departmentId, Long positionId);
    public User login(String username, String password);
    public List<User> findUserByDeptId(Long groupId);
    List<List<Object>> findUserGroupWfs(Long workflwProcessId);
    List<User> findUserByGroupWfs(Long workflwProcessId);
    public boolean searchUserToDelete(Long userId);
    
    /**
     * Returns a list of User objects.
     * There should normally only be one matching user.
     */
	public List<User> loadUsersByUsername(String username);
	
	/**
     * Loads authorities.
     *
     * @return a list of GrantedAuthority objects for the user
     */
	public List<String> loadUserAuthorities(String username);

}
